package com.hanggold.springboot.lesson4;

import javax.servlet.ServletContainerInitializer;
import java.util.Iterator;
import java.util.ServiceLoader;

public class SpiSeviceMain {


    public static void main(String[] args) {

        ServiceLoader<ServletContainerInitializer> servletContainerInitializers = ServiceLoader.load(ServletContainerInitializer.class);


      Iterator<ServletContainerInitializer> servletContainerInitializerIterator =  servletContainerInitializers.iterator();


      while (servletContainerInitializerIterator.hasNext()){


          ServletContainerInitializer servletContainerInitializer = servletContainerInitializerIterator.next();


          System.out.println("ServletContainerInitializer: "+ servletContainerInitializer.getClass().getName());


      }








    }
}
